package com.stm.bi.enums;

/**
 * @author chenyingjun
 * @ClassDesc 业态枚举
 * @date 2023/02/02 9:20
 **/
public enum BusinesFormat {

    COOPERATE_FORMAT("cooperate_format", "合作业态"),
    CHANNEL_FORMAT("channel_format", "渠道业态"),
    INVEST_FORMAT("invest_format", "投资业态"),
    LIFE_FORMAT("life_format", "生活业态");
    /**
     * 字段类型值
     */
    private final String value;
    /**
     * 字段类型描述
     */
    private final String desc;

    BusinesFormat(String value, String desc) {
        this.value = value;
        this.desc = desc;
    }

    public static BusinesFormat getFieldType(String value) {
        for (BusinesFormat ut : BusinesFormat.values()) {
            if (ut.getValue().equals(value)) {
                return ut;
            }
        }
        return null;
    }

    public String getValue() {
        return this.value;
    }

    public String getDesc() {
        return desc;
    }
}
